export  class ServiceProto {
    static loginMsgID = {
        pbname: "protobuf",
        HEART: 2,
        C2S_Login: 1001,
        S2C_Login: 1002,
        S2C_RoomInfo: 1003,
        C2S_RoleInfo:1004,
        S2C_RoleInfo:1005,
        S2C_LoginOut:1006,
        C2S_SendBullet:1007,
        S2C_SendBullet:1008,
    }

    static getMap(): any {
        let protoIDs = {}
        for (let key in ServiceProto.loginMsgID) {
            // console.log(index)
            const element = ServiceProto.loginMsgID[key];
            if (typeof (element) == "number") {
                // console.log(element)
                protoIDs[element] = { req: { pName: ServiceProto.loginMsgID.pbname ,mName:key}, res: {pName:ServiceProto.loginMsgID.pbname, mName: key } };
            }
        }

        return  protoIDs;
    }

}